# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
# Contributor: Sergej Pupykin <pupykin.s+aur@gmail.com>

pkgname=perl-email-mime-contenttype
pkgver=1.028
pkgrel=1
pkgdesc="Parse a MIME Content-Type Header "
arch=('any')
url="https://search.cpan.org/dist/Email-MIME-ContentType"
license=('GPL' 'PerlArtistic')
depends=('perl' 'perl-text-unidecode')
options=('!emptydirs')
source=(https://www.cpan.org/CPAN/authors/id/R/RJ/RJBS/Email-MIME-ContentType-$pkgver.tar.gz)
sha256sums=('e7950246433f7ed6c3e4fd4df2227e0f2341137c3cab1989018fc370f58145c4')

build() {
  cd  "$srcdir"/Email-MIME-ContentType-$pkgver
  PERL_MM_USE_DEFAULT=1 perl Makefile.PL INSTALLDIRS=vendor
  make
}

package() {
  cd  "$srcdir"/Email-MIME-ContentType-$pkgver
  make install DESTDIR="$pkgdir"
  find "$pkgdir" -name '.packlist' -delete
  find "$pkgdir" -name '*.pod' -delete
}
